
import {
  Column,
  CreateDateColumn,
  Entity,
  JoinTable,
  ManyToMany,
  OneToOne,
  PrimaryGeneratedColumn,
  UpdateDateColumn,
} from 'typeorm';
// import { Profile } from './profile.entity';
import { Role } from '@/modules/role/role.entity';

@Entity()
export class Player {
  @PrimaryGeneratedColumn()
  id: number;

  @Column({ length: 50 })
  player_name: string;

  @Column({ default: '00' })
  player_number: string;

  @Column({ default: '待定' })
  position: string;

  @Column()
  height: string;

  @Column()
  weight: string;

  @Column({ default: 0 })
  all_score: number;

  @Column({ default: 0 })
  all_foul: number;

  @Column({ default: 0 })
  ave_score: number;

  @Column({ default: 0 })
  ave_foul: number;

  @Column({ default: 7 })
  session: number;

  @Column({ default: 0 })
  team_id: number;

  // 总场次
  @Column({ default: 0 })
  total_field: number;

  @Column({ default: 'http://www.rsba.top/favicon.png' })
  avatar: string;

  @CreateDateColumn()
  createTime: Date;

  @UpdateDateColumn()
  updateTime: Date;
}
